v a r   c r u s t t y p e   =   d o c u m e n t . f o r m s [ " p i z z a f o r m " ] . c r u s t ; 
 
 v a r   c r u s t l e n g t h   =   c r u s t t y p e . l e n g t h ; 
 
 f o r   ( v a r   c   =   0 ;   c   <   c r u s t l e n g t h ;   c + + )   { 
 
         i f   ( c r u s t t y p e [ c ] . c h e c k e d )   { 
 
                     v a r   n e w e l e m e n t   =   d o c u m e n t . c r e a t e E l e m e n t ( " p " ) ; 
 
                     n e w e l e m e n t . s e t A t t r i b u t e ( " i d " , " c r u s t e l e m e n t "   +   i ) ; 
 
                     d o c u m e n t . b o d y . a p p e n d C h i l d ( n e w e l e m e n t ) ; 
 
                     n e w e l e m e n t . a p p e n d C h i l d ( d o c u m e n t . c r e a t e T e x t N o d e ( " V   b  n h :   "   +   c r u s t t y p e [ c ] . v a l u e ) ) ; 
 
         } 
 
 } 
 
 